load("@fbsource//tools/build_defs:rust_library.bzl", "rust_library")

oncall("buck2")

rust_library(
    name = "buck2_error",
    srcs = glob(
        ["src/**/*.rs"],
    ),
    named_deps = {
        # @oss-disable[end= ]: "edenfs_clients": "//eden/fs/service:thrift-rust-clients",
    },
    os_deps = [
        (
            "linux",
            [
                "fbsource//third-party/rust:nix",
            ],
        ),
        (
            "macos",
            [
                "fbsource//third-party/rust:nix",
            ],
        ),
    ],
    deps = [
        "fbsource//third-party/rust:anyhow",
        "fbsource//third-party/rust:clap",
        "fbsource//third-party/rust:derive_more",
        "fbsource//third-party/rust:fancy-regex",
        "fbsource//third-party/rust:hex",
        "fbsource//third-party/rust:http-1",
        "fbsource//third-party/rust:hyper-1-5-1",
        "fbsource//third-party/rust:hyper-util",
        "fbsource//third-party/rust:libc",
        "fbsource//third-party/rust:prost-0-13-4",
        "fbsource//third-party/rust:prost-types-0-13-4",
        "fbsource//third-party/rust:ref-cast",
        "fbsource//third-party/rust:regex",
        "fbsource//third-party/rust:relative-path",
        "fbsource//third-party/rust:rusqlite",
        "fbsource//third-party/rust:rustls-native-certs-0-8-1",
        "fbsource//third-party/rust:rustls-pki-types",
        "fbsource//third-party/rust:serde_json",
        "fbsource//third-party/rust:smallvec",
        "fbsource//third-party/rust:thiserror",
        "fbsource//third-party/rust:tokio",
        "fbsource//third-party/rust:toml",
        "fbsource//third-party/rust:tonic-0-12-3",
        "fbsource//third-party/rust:uuid",
        "//buck2/allocative/allocative:allocative",
        "//buck2/app/buck2_data:buck2_data",
        "//buck2/app/buck2_error_derive:buck2_error_derive",
        "//buck2/dice/dice_error:dice_error",
        "//buck2/gazebo/dupe:dupe",
        "//buck2/starlark-rust/starlark_syntax:starlark_syntax",
        "//buck2/superconsole:superconsole",
        "//watchman/rust/watchman_client:watchman_client",
    ],
)
